//
//  ForRefundBottomCell.m
//  CenturyCity
//
//  Created by beisheng03 on 2018/1/16.
//  Copyright © 2018年 beisheng. All rights reserved.
//

#import "ForRefundBottomCell.h"

@interface ForRefundBottomCell ()

@property (weak, nonatomic) IBOutlet UILabel *leftLabel;
@property (weak, nonatomic) IBOutlet UILabel *starLabel;
@property (weak, nonatomic) IBOutlet UITextField *rightTextField;

@end

@implementation ForRefundBottomCell

- (void)awakeFromNib {
    [super awakeFromNib];
    
    self.leftLabel.font = MYFONT(14);
    
    self.rightTextField.font = MYFONT(14);
    
    self.rightTextField.keyboardType = UIKeyboardTypeNumberPad;
    
    [[NSNotificationCenter defaultCenter]addObserver:self selector:@selector(textChange) name:UITextFieldTextDidChangeNotification object:self.rightTextField];
    
    self.starLabel.font = MYFONT(12);
    // Initialization code
}

- (void)setModel:(ApplyRefundParmModel *)model{
    
    _model = model;
    
    if (_model.refund_require_money.length > 0) {
        self.rightTextField.text = _model.refund_require_money;
    }
    
    self.rightTextField.placeholder = [NSString stringWithFormat:@"最多退款%@比索",_model.placehoder];
    
}




- (void)textChange{
    
    self.model.refund_require_money = self.rightTextField.text;

    
}


- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
